fs/zfs: Use safe math macros to prevent overflows
authorLidong Chen <lidong.chen@oracle.com>
Wed, 22 Jan 2025 07:17:02 +0000 (07:17 +0000)
committerMiao Wang <shankerwangmiao@gmail.com>
Sun, 15 Feb 2026 13:50:20 +0000 (13:50 +0000)
commit52ea15aafb94ed1f853a5c5adea885929df73882
tree5246c27b4d1aa478c7dbf80b094ee5618eacc098
parenteee111d1880ff84fc9cdcf3f92f04626a745f1ed
fs/zfs: Use safe math macros to prevent overflows

Replace direct arithmetic operations with macros from include/grub/safemath.h
to prevent potential overflow issues when calculating the memory sizes.

Signed-off-by: Lidong Chen <lidong.chen@oracle.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
Gbp-Pq: Topic cve-2025-jan
Gbp-Pq: Name fs-zfs-Use-safe-math-macros-to-prevent-overflows.patch
grub-core/fs/zfs/zfs.c